A database iterator can traverse records, for example, values of an attribute of a table stored in a database. The iterator can return an ordered sequence of the values and facilitate subsequent processing in conjunction with the traversal, such as retrieval, addition, and removal of database records. In some implementations, the values of an attribute can be stored in different physical parts of the database. Each part can have a distinct physical implementation, data type, or other properties, requiring an iterator specifically designed for this part of the database. It is desirable to have a generic iterator that can handle different implementations of a database and traverse all values of an attribute stored across multiple parts of a database in an effective and computationally efficient manner.